﻿using System.Collections.Generic;

namespace VisionCloud.Domain.DtoModel.Ms
{
    /// <summary>
    /// 分析报告Dto
    /// </summary>
    public class QualityAnalysisChartDto
    {
        public List<QualityAnalysisChartItem> Items { get; set; } = new List<QualityAnalysisChartItem>();
    }

    public class QualityAnalysisChartItem
    {
        /// <summary>
        /// 初测/复测
        /// </summary>
        public string StageName { get; set; }

        /// <summary>
        /// 综合合格率
        /// </summary>
        public TotalPass TotalPass { get; set; }

        /// <summary>
        /// 测量项合格率
        /// </summary>
        public List<MeasureItemData> MeasureItemData { get; set; }

        /// <summary>
        /// 楼栋合格率
        /// </summary>
        public List<BuildingData> BuildingData { get; set; }
    }

    /// <summary>
    /// 综合合格率
    /// </summary>
    public class TotalPass
    {
        /// <summary>
        /// 合格点数
        /// </summary>
        public int PassNum { get; set; }

        /// <summary>
        /// 爆点数
        /// </summary>
        public int FailureNum { get; set; }
    }

    /// <summary>
    /// 测量项合格率
    /// </summary>
    public class MeasureItemData
    {
        /// <summary>
        /// 测量项名称
        /// </summary>
        public string Title { get; set; }

        /// <summary>
        /// 测量项代码
        /// </summary>
        public string Code { get; set; }

        /// <summary>
        /// 爆点数
        /// </summary>
        public int PNum { get; set; }

        /// <summary>
        /// 测试总数
        /// </summary>
        public int CNum { get; set; }

        /// <summary>
        /// 合格率（注：不带%）
        /// </summary>
        public List<string> PassPercent { get; set; }
    }

    /// <summary>
    /// 楼栋合格率
    /// </summary>
    public class BuildingData
    {
        /// <summary>
        /// 测量项名称
        /// </summary>
        public string Title { get; set; }

        /// <summary>
        /// 测量项代码
        /// </summary>
        public string Code { get; set; }

        /// <summary>
        /// 单位：栋，层或户
        /// </summary>
        public string Unit { get; set; }

        /// <summary>
        /// 合格率（注：不带%，X轴坐标一一对应）
        /// </summary>
        public List<string> PassPercent { get; set; }

        /// <summary>
        /// X轴坐标刻度
        /// </summary>
        public List<string> XAxis { get; set; }

        /// <summary>
        /// 爆点数
        /// </summary>
        public int PNum { get; set; }

        /// <summary>
        /// 测试总数
        /// </summary>
        public int CNum { get; set; }
    }
}